/**
 * description：webpack之vue解析配置
 * author：
 * */
const utils = require("./utils");
const VueLoaderPlugin = require('vue-loader/lib/plugin');

module.exports = {
    module: {
        rules: [
            {
                test: /\.vue$/,
                include: [utils.resolve('client'), utils.resolve('node_modules/element-ui/packages')],
                use: ['vue-loader'], // vue-loader 15.X后不支持使用happypack插件
            }
        ]
    },
    resolve: {
        extensions: ['.js', '.vue', '.json'],
        alias: {
            vue: 'vue/dist/vue.esm.js'
        }
    },
    plugins: [
        new VueLoaderPlugin(),
    ]
};
